---
sidebar_position: 1
description: DragSelect is very simple to use and has a lot of features. It's a pure JavaScript library that doesn't depend on any other libraries. Learn how to use it in this tutorial.
---

# Simple

The simplest possible use-case. Is to choose which elements can be selected:

```javascript
new DragSelect({
  selectables: document.getElementsByClassName('selectable-nodes')
});
```

That’s it. Check it out:

<iframe height="400" style={{ width: '100%' }} scrolling="no" title="DragSelect with Scrollable AREA" src="https://codepen.io/ThibaultJanBeyer/embed/prpwYG?default-tab=result&editable=true&theme-id=dark" frameBorder="no" loading="lazy" allowtransparency="true" allowFullScreen>
  See <a href="https://codepen.io/ThibaultJanBeyer/pen/prpwYG">this Pen about DragSelect</a> on CodePen.
</iframe>
